#pragma once

#include "GLDrawable.h"

class GLLine : public GLDrawable
{
	using Super = GLDrawable;

public:
	using Super::Super;

	void setStart(const QPoint& pos)
	{
		mStart = pos;
	}
	void setStop(const QPoint& pos)
	{
		mStop = pos;
	}

	const QPoint& start() const
	{
		return mStart;
	}
	const QPoint& stop() const
	{
		return mStop;
	}
	QVector<QVector3D> getVertices() const;

	// 组件整体变换用的矩阵
	const QMatrix4x4& compMat() const;
	void			  setCompMat(const QMatrix4x4& mat);

private:
	QPoint mStart;
	QPoint mStop;
	QMatrix4x4 mCompMat;
};
